<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="description" content="">
    <meta name="author" content="">
    <link rel="shortcut icon" href="/favicon.jpg">

    <title>快乐零食</title>

    <!-- Bootstrap core CSS -->
    <link href="/lib/yeti/css/bootstrap.min.css" rel="stylesheet">

    <style type="text/css" media="">
    #logo{
        width:80px;
    }
    .breadcrumb {
        font-size:12px;
    }
    .panel {
        padding-left:0px;
        padding-right:0px;
    }
    .navbar-inverse {
        background-color: #EB6C4C;
        border-color: #006687;
    }
    

    /*下面是位置定义*/
    .center {
        width: auto;
        display: table;
        margin-left: auto;
        margin-right: auto;
    }
    .right {
        display: inline-block;
        min-width: 10px;
        line-height: 1;
        vertical-align: baseline;
        white-space: nowrap;
        text-align: center;
        float:right;
    }
    .text-center {
        text-align: center;
    }

    /* 页面选择按钮样式 */
    .selected {
    background-color: #eeeeee !important;
    border-color: transparent;
    }
    </style>

    <!-- Just for debugging purposes. Don't actually copy this line! -->
    <!--[if lt IE 9]><script src="../../assets/js/ie8-responsive-file-warning.js"></script><![endif]-->

    <!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
    <!--[if lt IE 9]>
      <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
      <script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script>
    <![endif]-->
  </head>

  <body>

    <!-- Static navbar -->
    <div class="navbar navbar-inverse">
        <div class="navbar-header">
            <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-inverse-collapse">
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
            </button>
            <a href="/">
                <img id="logo" src="/images/title.png" />
            </a>
        </div>
        <div class="navbar-collapse collapse navbar-inverse-collapse">
            <ul class="nav navbar-nav navbar-right">
                <li>
                <?php $username =  Yaf_Session::getInstance()->get("username");
                    if (isset($username)&& $username!="") {
                ?>
                <a href="/user/logout">退出登录</a>
                <?php }else{ ?>
                <a href="/user/login">登陆</a>
                <?php } ?>
                </li>
                <li class="dropdown">
                <a href="#" class="dropdown-toggle" data-toggle="dropdown">个人账户<b class="caret"></b></a>
                <ul class="dropdown-menu">
                    <li><a href="/fav/list">收藏夹</a></li>
                    <li class="divider"></li>
                    <li><a href="/admin">网站后台管理</a></li>
                    <li><a href="/user/logout">登出</a></li>
                </ul>
                </li>
            </ul>
        </div>
    </div>

<ul class="nav nav-pills">
    <li class="col-lg-3 col-xs-3 btn-group">
        <button href="#" class="btn btn-sm btn-success dropdown-toggle" data-toggle="dropdown">分类<p class="caret"></p></button>
        <ul class="dropdown-menu">
            <li><a href="/item/category?id=1"><strong>休闲零食</strong></a></li>
            <li><a href="/item/category?id=2">坚果炒货</a></li>
            <li><a href="/item/category?id=3">肉干肉脯</a></li>
            <li class="divider"></li>
            <li><a href="/item/category?id=4"><strong>开心零食</strong></a></li>
            <li><a href="/item/category?id=5">糖果/巧克力</a></li>
            <li><a href="/item/category?id=6">饼干蛋糕</a></li>
        </ul>
    </li>
    <li class="col-lg-6 col-xs-5">
        <div class="input-group">
            <input type="text" class="form-control js-search-name" placeholder="输入零食名称" value='<?php if (isset($product_name) && $product_name) echo $product_name;else echo ""; ?>'>
            <span class="input-group-btn">
                <button class="btn btn-default js-search-btn" type="button">搜索</button>
            </span>
        </div><!-- /input-group -->
    </div><!-- /.col-lg-6 -->
    </li>
    <li class="col-lg-1 col-xs-1 navbar-right">
        <span>
            <a href="/order/list" class="btn btn-sm btn-danger">购物车</a>
        </span>
    </li>
</ul>


<p class="clearfix"></p>
